﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="AdminUser.aspx.cs" Inherits="XMLMovieWebsite.AdminUser" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
      <title></title>
    <link href="Styles/bootstrap.css" rel="stylesheet" />
     <!-- FontAwesome Styles-->
    <link href="Styles/font-awesome.css" rel="stylesheet" />
        <!-- Custom Styles-->
    <link href="Styles/custom-styles.css" rel="stylesheet" />
     <!-- Google Fonts-->
   <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css' />
</head>
<body>
    <form id="form1" runat="server">
    <div id="wrapper">
       <nav class="navbar navbar-default top-navbar" role="navigation">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".sidebar-collapse">
                    <span class="sr-only">Toggle navigation</span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
                <a class="navbar-brand" href="#">Administrator</a>
            </div>

            <ul class="nav navbar-top-links navbar-right">
                <!-- /.dropdown -->
                <li class="dropdown">
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#" aria-expanded="false">
                        <img src="images/icon/user.png"/></i>
                    </a>
                    <ul class="dropdown-menu dropdown-user">
                        <li><a href="#"><img src="images/icon/id_card.png"/> Thông tin</a>
                        </li>
                        <li class="divider"></li>
                        <li><a href="#"><img src="images/icon/cancel.png"/> Logout</a>
                        </li>
                    </ul>
                    <!-- /.dropdown-user -->
                </li>
                <!-- /.dropdown -->
            </ul>
        </nav>
        <!--/. NAV TOP  -->
        <nav class="navbar-default navbar-side" role="navigation">
            <div class="sidebar-collapse">
                <ul class="nav" id="main-menu">
                    <li>
                        <a href="AdminMainPage.aspx" class="active-menu"><img src="images/icon/add.png"/> Thêm Phim</a>
                    </li>
                    <li>
                        <a href="#"><img src="images/icon/database.png"/> Dữ Liệu</a>
                        <ul class="nav nav-second-level">
                            <li>
                                <a href="AdminUser.aspx">Danh Sách Người Dùng</a>
                            </li>
                            <li>
                                <a href="AdminFilm.aspx">Danh Sách Phim</a>
                            </li>
                        </ul>
                    </li>
                </ul>

            </div>

        </nav>
        <!-- /. NAV SIDE  -->
        <div id="page-wrapper" >
            <div id="page-inner">
			 <div class="row">
                    <div class="col-md-12">
                        <h1 class="page-header">
                            XML Movie <small>Danh Sách Người Dùng</small>
                        </h1>
                    </div>
                </div> 
                 <!-- /. ROW  -->
               
            <div class="row">
                <div class="col-md-12">
                    <!-- Advanced Tables -->
                    <div class="panel panel-default">
                        <div class="panel-heading">
                             Trang Danh Sách Người Dùng
                        </div>
                        <div class="panel-body">
                            <div class="table-responsive">
                              <asp:DataList ID="DataList1" runat="server"  
                                    DataSourceID="SqlDataSource1" 
                                    oneditcommand="DataList1_EditCommand" 
                                    oncancelcommand="DataList1_CancelCommand" 
                                    ondeletecommand="DataList1_DeleteCommand" 
                                    onitemcommand="DataList1_ItemCommand">
                         <ItemTemplate>
                                <table class="table table-striped table-bordered table-hover" id="dataTables-example">
                                    <thead>
                                        <tr>
                                            <th>Username</th>
                                            <th>Password</th>
                                            <th>Email</th>
                                            <th>Địa Chỉ</th>
                                            <th>Ngày Gia Nhập</th>
                                            <th>Thao Tác</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                        <tr class="odd gradeX">
                                            <asp:Label ID="Label1" runat="server" Text='<%#Eval("username")%>' Visible="False"></asp:Label>
                                            <td><%#Eval("username")%></td>
                                            <td><%#Eval("password")%></td>
                                            <td class="center"><%#Eval("email")%></td>
                                            <td class="center"><%#Eval("diachi")%></td>
                                            <td class="center"><%#Eval("date")%></td>
                                               <td class="center">
                                                 <asp:Button ID="Button1" runat="server" Text="CT" CommandName="ChiTiet" />
                                                 <asp:Button ID="Button2" runat="server" Text="ED" CommandName="Edit" />
                                                 <asp:Button ID="Button3" runat="server" Text="DEL" CommandName="Delete" />
                                                 </td>
                                        </tr>
                                    </tbody>
                                </table>
                                </ItemTemplate>
                                <EditItemTemplate>
                                        <table class="table table-striped table-bordered table-hover" id="dataTables-example">
                                    <thead>
                                        <tr>
                                            <th>Username</th>
                                            <th>Password</th>
                                            <th>Email</th>
                                            <th>Địa Chỉ</th>
                                            <th>Ngày Gia Nhập</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                        <tr class="odd gradeX">
                                            <td><asp:TextBox ID="TextBox1" runat="server" Text=' <%#Eval("username")%> ' Enabled="False"></asp:TextBox></td> 
                                            <td><asp:TextBox ID="TextBox2" runat="server" Text=' <%#Eval("password")%> '></asp:TextBox></td> 
                                            <td class="center"><asp:TextBox ID="TextBox3" runat="server" Text=' <%#Eval("email")%> ' Enabled="true"></asp:TextBox></td> 
                                            <td class="center"><asp:TextBox ID="TextBox4" runat="server" Text=' <%#Eval("diachi")%> '></asp:TextBox></td> 
                                            <td class="center"><asp:TextBox ID="TextBox5" runat="server" Text=' <%#Eval("date")%> ' Enabled="False"></asp:TextBox></td> 
                                             <td class="center">
                                                 <asp:Button ID="Button1" runat="server" Text="Update" CommandName="Update" />
                                                 <asp:Button ID="Button2" runat="server" Text="Cancel" CommandName="Cancel" />
                                                 </td>
                                        </tr>
                                    </tbody>
                                </table>
                                
                                
                                
                                </EditItemTemplate>


                                </asp:DataList>
                                 <asp:SqlDataSource ID="SqlDataSource1" 
                    runat="server" 
                    ConnectionString="<%$ ConnectionStrings:ConStringXml %>" 
                    SelectCommand="SELECT * FROM [taikhoan]">
                </asp:SqlDataSource>
                            </div>
                            
                        </div>
                    </div>
                    <!--End Advanced Tables -->
                </div>
            </div>
                <!-- /. ROW  -->
           
        </div>
    </div>
             <!-- /. PAGE INNER  -->
            </div>
         <!-- /. PAGE WRAPPER  -->
     <!-- /. WRAPPER  -->
    <!-- JS Scripts-->
    <!-- jQuery Js -->
    <script src="assets/js/jquery-1.10.2.js"></script>
      <!-- Bootstrap Js -->
    <script src="assets/js/bootstrap.min.js"></script>
    <!-- Metis Menu Js -->
    <script src="assets/js/jquery.metisMenu.js"></script>
     <!-- DATA TABLE SCRIPTS -->
    <script src="assets/js/dataTables/jquery.dataTables.js"></script>
    <script src="assets/js/dataTables/dataTables.bootstrap.js"></script>
        <script>
            $(document).ready(function () {
                $('#dataTables-example').dataTable();
            });
    </script>
         <!-- Custom Js -->
    <script src="assets/js/custom-scripts.js"></script>
    
   <</form>
</body>
</html>
